
import React, { Component } from 'react'
import { Button } from 'antd-mobile'
import { BrowserRouter as Router,Link,Route,Redirect } from 'react-router-dom'

import Home from './pages/Home'

import CityList from './pages/CityList'

export default class App extends Component {
  render() {
    return (
      <Router>

        <ul>
          <li><Link to='/home'>主页</Link></li>
          <li><Link to='/CityList'>城市列表</Link></li>
        </ul>

        <Route path="/home" component={Home}></Route>
        <Route path="/CityList" component={CityList}></Route>
        <Redirect to='/home'></Redirect>
      </Router>
    )
  }
}



